package com.chen.service.impl;

import com.chen.dao.UserDao;
import com.chen.pojo.User;
import com.chen.service.UserServiec;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @Author zhebie
 * @DATE 2021/9/20
 */
@Service
public class UserServiecImpl implements UserServiec {

    @Autowired
    private UserDao userdao;

    /**
     * 通过用户名查询数据库，获取用户信息包含用户的所有角色及角色下的所有权限
     * @param username
     * @return
     */
    @Override
    public User findByUsername(String username) {
        return userdao.findByUsername(username);
    }
}
